# Maintainer: Maxime Gauduin <alucryd@archlinux.org>

pkgname=python-django-modeltranslation
pkgver=0.18.9
pkgrel=2
pkgdesc='Translates Django models using a registration approach'
arch=(any)
url=https://github.com/deschler/django-modeltranslation
license=(BSD)
depends=(python-django)
makedepends=(
  git
  python-setuptools
)
_tag=6ed72902fd749f3081963ea10d31604f25fa0625
source=(git+https://github.com/deschler/django-modeltranslation.git#tag=${_tag})
sha256sums=(SKIP)

pkgver() {
  cd django-modeltranslation

  git describe --tags | sed 's/^v//'
}

build() {
  cd django-modeltranslation

  python setup.py build
}

package() {
  cd django-modeltranslation

  python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
  install -Dm 644 LICENSE.txt -t "${pkgdir}"/usr/share/licenses/python-django-modeltranslation/
}

# vim: ts=2 sw=2 et:
